package com.example.fishscavengerhunt;

import android.os.Bundle;
import android.app.Activity;
import android.content.Intent;
import android.view.Menu;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.ImageButton;

public class RiverScout extends Activity {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_river_scout);
		final Button scanButton = (Button) findViewById(R.id.scan);
		scanButton.setOnClickListener(new View.OnClickListener() {
			public void onClick(View v) {
				Intent myIntent = new Intent(RiverScout.this, QRScan.class);
				RiverScout.this.startActivity(myIntent);
			}
		});
		final Button tankButton = (Button) findViewById(R.id.tank);
		tankButton.setOnClickListener(new View.OnClickListener() {
			public void onClick(View v) {
				Intent myIntent = new Intent(RiverScout.this, Tank.class);
				RiverScout.this.startActivity(myIntent);
			}
		});

		((ImageButton) findViewById(R.id.back))
				.setOnClickListener(new OnClickListener() {

					@Override
					public void onClick(View v) {
						finish();
					}
				});
		((ImageButton) findViewById(R.id.home))
		.setOnClickListener(new OnClickListener() {
			@Override
			public void onClick(View v) {
				Intent newIntent = new Intent(RiverScout.this, Main.class);
            	RiverScout.this.startActivity(newIntent);
            	finish();
			}
		});
	}

	@Override
	public boolean onCreateOptionsMenu(Menu menu) {
		// Inflate the menu; this adds items to the action bar if it is present.
		getMenuInflater().inflate(R.menu.river_scout, menu);
		return true;
	}

}
